<?php if (!defined('THINK_PATH')) exit(); /*a:2:{s:75:"/phpstudy/www/xxm.com/public/../project/app/admin/view/system/bank_add.html";i:1555401366;s:75:"/phpstudy/www/xxm.com/public/../project/app/admin/view/layout_menu_all.html";i:1555401363;}*/ ?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
    <meta http-equiv="Cache-Control" content="max-age=2592000" />
    <title><?php echo config('website_title'); ?></title>
    <link href="__STATIC__/favicon.ico" rel="shortcut icon">
    <link href="__STATIC__/admin/css/base.css" rel="stylesheet">
    <link href="__STATIC__/admin/css/index.css" rel="stylesheet" />
    <link href="__STATIC__/admin/css/system.css" rel="stylesheet" />
    <script type="text/javascript" src="__STATIC__/common/jquery-1.8.3.min.js"></script>
    <script type="text/javascript" src="__STATIC__/common/jquery.validate.js"></script>
    <script type="text/javascript" src="__STATIC__/common/jquery.metadata.js"></script>
    <script type='text/javascript' src="__STATIC__/common/jquery.resizableColumns.js"></script>
    <script type="text/javascript" src="__STATIC__/common/plugins/layer/layer.min.js"></script>
    <script type="text/javascript" src="__STATIC__/admin/js/common.js?v=1.0"></script>
    <script type="text/javascript" src="__STATIC__/common/json2.js"></script>
    <script type="text/javascript">
        var json = JSON.parse('<?php echo \think\Config::get('json'); ?>');
        var upload_url = "<?php echo url('common/file'); ?>";
    </script>
</head>
<body>
    <div class="warp tree">
        <div class="head-content">
            <!-- 页面head -->
            <div class="head">
                <div class="user-logo" style="color: #fff;font-size: 30px;width:500px;font-family:Arial,Helvetica,sans-serif;"><?php echo config('website_title'); ?></div>
                <div class="user-info">
                    <p>
                        欢迎[<font color="red"><?php echo get_login_admin_role_name(); ?></font>]<a href="<?php echo Url('admin/admin_info'); ?>"><?php echo get_login_admin_user(); ?></a>的到来 |
                        <!--<a href="<?php echo Url('system/clear_cache_all'); ?>">最新消息（<font color="red">10</font>）</a> |-->
                        <a href="<?php echo Url('system/clear_cache_all'); ?>">清除缓存</a> |
                        <a href="<?php echo Url('login/logout'); ?>">退出</a>
                    </p>
                    <p><span>版本：1.0.0</span><span>最后登录IP：<?php echo get_client_ip(); ?></span></p>
                </div>
            </div>

            <!-- 一级菜单 -->
            <div class="nav-box">
                <ul class="nav" id="_menu_one">
                    <?php if(is_array(\think\Config::get('menu.menu')[1]) || \think\Config::get('menu.menu')[1] instanceof \think\Collection || \think\Config::get('menu.menu')[1] instanceof \think\Paginator): if( count(\think\Config::get('menu.menu')[1])==0 ) : echo "" ;else: foreach(\think\Config::get('menu.menu')[1] as $key=>$menu_one): if(($menu_one['menu_id'] == \think\Config::get('menu.current')[1])): ?>
                            <li class="cur"><a href="<?php echo Url($menu_one['action']); ?>"><span><?php echo $menu_one['name']; ?></span></a></li>
                        <?php else: ?>
                            <li><a href="<?php echo Url($menu_one['action']); ?>"><span><?php echo $menu_one['name']; ?></span></a></li>
                        <?php endif; endforeach; endif; else: echo "" ;endif; ?>
                </ul>
            </div>

            <!-- 内容 -->
            <div class="container">
                <!-- 二级菜单 -->
                <div class="side fl mt10">
                    <!-- 二级菜单 -->
                    <div class="scroll-bar-box">
                        <div class="view-port">
                            <div id="overviewTreeGroup" class="overview">
                                <ul id="_menu_two">
                                    <?php if(is_array(\think\Config::get('menu.menu')[2]) || \think\Config::get('menu.menu')[2] instanceof \think\Collection || \think\Config::get('menu.menu')[2] instanceof \think\Paginator): if( count(\think\Config::get('menu.menu')[2])==0 ) : echo "" ;else: foreach(\think\Config::get('menu.menu')[2] as $key=>$menu_two): if(($menu_two['menu_id'] == \think\Config::get('menu.current')[2])): ?>
                                            <li class="cur"><a href="<?php echo Url($menu_two['action']); ?>"><span><?php echo $menu_two['name']; ?></span></a></li>
                                        <?php else: ?>
                                            <li><a href="<?php echo Url($menu_two['action']); ?>"><span><?php echo $menu_two['name']; ?></span></a></li>
                                        <?php endif; endforeach; endif; else: echo "" ;endif; ?>
                                </ul>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- 页面主体内容 -->
                <div class="cont mt10">
                    <!-- 收缩条 -->
                    <div id="content_hide" style="position: relative; left:-10px; top: 285px;" ret="1">
                        <div class="effect-btn">
                            <img src="__STATIC__/admin/css/img/btn_icon02.gif" class="left">
                        </div>
                    </div>

                    <!-- 搜索框及工具条 -->
                    <div class="crumbs-box">
                        <div class="crumbs">
                            <!-- 导航条 -->
                            <div class="fl" id="_mini_nav">
                                <a class='blue' href='<?php echo Url(\think\Config::get('menu')["menu"][1][\think\Config::get('menu')["current"][1]]["action"]); ?>'><?php echo \think\Config::get('menu')["menu"][1][\think\Config::get('menu')["current"][1]]["name"]; ?></a>&nbsp;>&nbsp;
                                <a class='blue' href='<?php echo Url(\think\Config::get('menu')["menu"][2][\think\Config::get('menu')["current"][2]]["action"]); ?>'><?php echo \think\Config::get('menu')["menu"][2][\think\Config::get('menu')["current"][2]]["name"]; ?></a>&nbsp;>&nbsp;
                                <a class='blue' href='<?php echo Url(\think\Config::get('menu')["menu"][3][\think\Config::get('menu')["current"][3]]["action"]); ?>'><?php echo \think\Config::get('menu')["menu"][3][\think\Config::get('menu')["current"][3]]["name"]; ?></a>
                            </div>

                            <!-- 返回 -->
                            <span><a class="return" href="javascript:history.go(-1);">返回上一页</a></span>
                        </div>
                    </div>

                    <!-- 编辑区域 -->
                    <div class="lists">
                        <!-- 三级菜单 -->
                        <div class="lists-tab">
                            <strong>
                                <!-- 设置第四级菜单 -->
                                <ul id="_menu_three">
                                    <!-- 设置第四级菜单 -->
                                    <?php if(is_array(\think\Config::get('menu.menu')[3]) || \think\Config::get('menu.menu')[3] instanceof \think\Collection || \think\Config::get('menu.menu')[3] instanceof \think\Paginator): if( count(\think\Config::get('menu.menu')[3])==0 ) : echo "" ;else: foreach(\think\Config::get('menu.menu')[3] as $key=>$menu_three): if(($menu_three['menu_id'] == \think\Config::get('menu.current')[3])): ?>
                                            <li class="current"><a href="<?php echo Url($menu_three['action']); ?>"><?php echo $menu_three['name']; ?></a></li>
                                        <?php else: ?>
                                            <li><a href="<?php echo Url($menu_three['action']); ?>"><?php echo $menu_three['name']; ?></a></li>
                                        <?php endif; endforeach; endif; else: echo "" ;endif; ?>
                                </ul>
                            </strong>
                        </div>

                        <!-- Layout加载内容-->
                        <!--添加用户表单-->
<div class="tab_edit">
    <form action="<?php echo Url('bank_edit_submit'); ?>" method="post" id="bank_edit_submit">
        <table width="100%" class="list">
            <tr>
                <td class="t_r t_left_w">选择银行分类：</td>
                <td class="t_l"><?php echo widget('common/Select/select',array('bank_type_id',array($bank_type_list,"bank_type_id","bank_type_name"),null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">银行名称：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("bank_name",null,true,false)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">银行图标：</td>
                <td class="t_l"><?php echo widget('common/Images/wos',array('bank_url','credit',null,false,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">银行带文字图标：</td>
                <td class="t_l"><?php echo widget('common/Images/wos',array('bank_word_url','credit',null,false,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">银行概要：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("bank_outline",null,true,false,"width:800px;")); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡发卡率：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('pass_rate','rate',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡优惠力度：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('discount_rate','rate',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡发卡速度：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('send_rate','rate',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡批卡速度描述：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("ratify_velocity",null,true,false)); ?> 备注：例如3-7天批卡</td>
            </tr>
            <tr>
                <td class="t_r t_left_w">普卡额度范围：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("general",null,true,false)); ?> 备注：例如3000-30000</td>
            </tr>
            <tr>
                <td class="t_r t_left_w">金卡额度范围：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("gold",null,true,false)); ?> 备注：例如5000-50000</td>
            </tr>
            <tr>
                <td class="t_r t_left_w">白金额度范围：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("platinum",null,true,false)); ?> 备注：例如10万以上</td>
            </tr>
            <tr>
                <td class="t_r t_left_w">热线：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("heat",null,true,false)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">专线：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("specially",null,true,false)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡进度查询地址(手机端)：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("credit_schedule_url",null,false,false,"width:800px;")); ?><font color="red">（包括http或https）</font></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">信用卡进度查询地址(电脑端)：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("credit_schedule_url_pc",null,false,false,"width:800px;")); ?><font color="red">（包括http或https）</font></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">是否支持信用卡：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('is_credit','is_credit',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">是否有房贷：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('is_house','is_yes',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">是否热门：</td>
                <td class="t_l"><?php echo widget('common/Radio/radio',array('is_hot','is_hot',null,true)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">排序：</td>
                <td class="t_l"><?php echo widget("common/Input/input",array("order_by",0)); ?></td>
            </tr>
            <tr>
                <td class="t_r t_left_w">备注：</td>
                <td class="t_l">
                    <?php echo widget('common/TextArea/text_area',array('remark',null,false,false,"width:800px;")); ?>
                </td>
            </tr>
            <tr>
                <td class="t_r t_left_w"></td>
                <td class="t_l">
                    <div class="btn"><input type="submit" class="but_blue" value="保存信息"></div>
                </td>
            </tr>
        </table>
    </form>
</div>
<!-- JS处理 -->
<script language="javascript">
    $(function() {
        //有效区域
        var area_tpl = {
            getTemplate: function (info) {
                return '' +
                    '<tr class="info">' +
                    '<td><input type="hidden" name="area[]" value="' + info.data + '">' + info.content + '</td>' +
                    '<td>' + info.arr_house_rate_one + '</td>' +
                    '<td>' + info.arr_house_rate_two + '</td>' +
                    '<td>' + info.arr_house_rate_three + '</td>' +
                    '<td><a class="del" href="javascript:void(0);" class="blue"><b>删除</b></a></td>' +
                    '</tr>';
            }
        };

        //添加关联有效区域
        $("a#area_add").click(function(){
            //初期化变量
            var area = $("select[cache='credit_area'] option:selected");
            var province_id = parseInt(area.eq(0).val());
            var province_name = area.eq(0).text();
            var city_id = parseInt(area.eq(1).val());
            var city_name = area.eq(1).text();
            var arr_house_rate_one = $('input[name=arr_house_rate_one]').val();
            var arr_house_rate_two = $('input[name=arr_house_rate_two]').val();
            var arr_house_rate_three = $('input[name=arr_house_rate_three]').val();

            if(arr_house_rate_one <=0){
                alert("请填写首套利率！");
                return false;
            }

            if(arr_house_rate_one <=0){
                alert("请填写二套利率！");
                return false;
            }
            if(arr_house_rate_one <=0){
                alert("请填写三套利率！");
                return false;
            }

            //判断是否数据是否存在
            if(province_id > 0 && city_id > 0 ) {
                //添加到列表中
                $("tr#area_extend").after(area_tpl.getTemplate({
                    data: province_id + "," + city_id + "," + arr_house_rate_one + "," + arr_house_rate_two + "," + arr_house_rate_three,
                    content: province_name + "、" + city_name,
                    arr_house_rate_one:arr_house_rate_one,
                    arr_house_rate_two:arr_house_rate_two,
                    arr_house_rate_three:arr_house_rate_three
                }));
            }else{
                alert("请选择有效区域的省份及城市！");
            }
        });

        //删除关联有效区域
        $("a.del").live("click",function(){
            //删除多余数据
            $(this).parents("tr.info").remove();
        });
    });

</script>

                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="footer_gp">
        <p>厦门酷融信息科技有限公司版权所有 © Copyright 2014-2017 	闽ICP备18006609号-1</p>
    </div>
</body>
<!-- JS处理 -->
<script language="javascript">
    $(function(){
        //修改列表宽度
        $("div.lists-table table.pointer").width("<?php echo get_screen(); ?>");

        //二级菜单显示异常操作
        $('#content_hide').click(function(){
            //判断二级菜单是否显示
            if($(this).attr("ret") == 1){
                $(this).attr("ret","2");
                $("div.container .side").hide();
                $("div.container .cont").css("width","98.7%");
                $(this).find("img").attr("src","__STATIC__/admin/css/img/btn_icon01.gif");
            }else{
                $(this).attr("ret","1");
                $("div.container .side").show();
                $("div.container .cont").css("width","85.6%");
                $(this).find("img").attr("src","__STATIC__/admin/css/img/btn_icon02.gif");
            }
        });

        //修改列表宽度
        $("div.lists-table table").resizableColumns(function(){});

        //数据检查
        $.metadata.setType('attr', 'validate');
        $('form').validate();

        //重写alert
        window.alert = layer.alert;
    });
</script>
</html>